package com.shinbada.modules.competitor.mapper;

import com.shinbada.modules.competitor.entity.CompetitorProductDataItem;
import com.shinbada.modules.competitor.entity.DTO.ParamModelSelectionDTO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import com.shinbada.core.persistence.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import com.shinbada.modules.competitor.entity.CompetitorNoumenonDataItem;

import java.util.List;

/**
 * 本体-数据项MAPPER接口
 * @author initcap
 * @version 2021-08-11
 */
@Mapper
@Repository
public interface CompetitorNoumenonDataItemMapper extends BaseMapper<CompetitorNoumenonDataItem> {
    /**
     * 根据数据项类型和数据项获取本体数据项集
     * @param competitorProductDataItem
     * @return
     */
    List<CompetitorNoumenonDataItem> getTypeAndNameByDataItemValue(CompetitorProductDataItem competitorProductDataItem);

    /**
     * 根据本体ids 获取相关数据集
     * @param noumenonIds
     * @return
     */
    List<CompetitorNoumenonDataItem> selectNoumenonDataItemListByIds(@Param("noumenonIds") String[] noumenonIds);

    /**
     * 根据数据项id 和值获取本体id数组
     * @param paramModelSelectionDTOList
     * @return
     */
    String[] selectNoumenonByItemIdAndValue(@Param("paramModelSelectionDTOList") List<ParamModelSelectionDTO> paramModelSelectionDTOList);
}
